<!--
  @author heguanghua
  @since 2020/05/26 15:07
-->
<!DOCTYPE html SYSTEM "http://www.thymeleaf.org/dtd/xhtml1-strict-thymeleaf-4.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org">

<table class="layui-hide" id="zmn-table" lay-filter="zmn-table" th:fragment="table">
    <thead >
        <tr>
            <th lay-data="{type:'radio', width:50, unresize:true, align:'center', fixed:'left'}" th:if="${multi == null || multi != 2}"></th>
            <th lay-data="{type:'checkbox', width:50, unresize:true, align:'center', fixed:'left'}" th:if="${multi != null && multi == 2}"></th>
            <th lay-data="{field:'channelId', width:80, unresize:true, align:'center'}">渠道ID</th>
            <th lay-data="{field:'name', width:260, unresize:true, align:'left'}">渠道名称</th>
            <th lay-data="{field:'companyName', unresize:true, align:'left'}">公司名称</th>
            <th lay-data="{field:'status', width:80, unresize:true, align:'center'}">状态</th>
            <th lay-data="{field:'操作', width:80, unresize:true, align:'center', fixed:'right'}"></th>
        </tr>
    </thead>
    <tbody>
        <tr th:each="item:${items}">
            <td></td>
            <td th:text="${item.channelId}">channelId</td>
            <td>
                <span th:class="${'zmn-level ' + (item.rank == 1 ? 'zmn-level-1' : 'zmn-level-2')}" th:text="${item.rank}" th:title="${item.rank + '级渠道'}">level</span>
                <span th:text="${item.name}">name</span>
            </td>
            <td th:text="${item.companyName}">remark</td>
            <td>
                <span th:class="${item.status * 1 == 2 ? 'status-green' : 'status-gray'}" th:text="${T(com.zmn.common.dictionary.GlobalDict).getStatus(item.status * 1)}">status</span>
            </td>
            <td>
                <a href="javascript:void(0);" class="layui-btn layui-btn-xs layui-btn-normal" lay-event="add">选择</a>
            </td>
        </tr>
    </tbody>
</table>
